package top.infopub.mgr.sg.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import top.infopub.generic.GenericDao;
import top.infopub.generic.GenericServiceImpl;
import top.infopub.mgr.sg.dao.CitySurveyAttDao;
import top.infopub.model.sg.CitySurveyAtt;
import top.infopub.mgr.sg.service.CitySurveyAttService;

@Service
public class CitySurveyAttServiceImpl extends GenericServiceImpl<CitySurveyAtt, String> implements
		CitySurveyAttService {

	@Autowired
	private CitySurveyAttDao citySurveyAttDao;
	
	@Override
	public GenericDao<CitySurveyAtt, String> getDao() {
		return citySurveyAttDao;
	}

	//通过城市调研信息id查询附件集合
    @Override
    public List<CitySurveyAtt> selectByCityKey(String id) {
        CitySurveyAtt where = new CitySurveyAtt();
        where.setSurveyId(id);
        List<CitySurveyAtt> list = citySurveyAttDao.selectByEntityWhere(where);
        return list;
    }

}